{% do script(['app/js/upload-image/index.js']) %}

<div class="cd-image-upload">
  <img class="{{ imageClass }} js-upload-cover" id="{{ targetImg }}" src="{{ imageSrc }}">
  <div class="image-upload-mask">
    <div class="image-upload-content">
      <i class="cd-icon cd-icon-camera"></i>
      {{ imageText }}
    </div>
  </div>
  <label class="image-upload-label">
    <input type="file" name="file" class="js-upload-input hidden" accept="image/bmp,image/jpeg,image/png, image/jpg"
    data-token="{{ upload_token( uploadToken|default('default'), 'image') }}" 
    data-file-upload="{{path('file_upload')}}" 
    data-crop="{{ path('file_img_crop') }}"
    data-save-url="{{ saveUrl }}"
    data-target-img="#{{ targetImg }}"
    data-crop-width="{{ cropWidth }}"
    data-crop-height="{{ cropHeight }}" />
  </label>
</div>